Termination w.r.t. Q of the following Term Rewriting System could not be shown:

Q restricted rewrite system:
The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.


QTRS
  ↳ DependencyPairsProof

Q restricted rewrite system:
The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.

Using Dependency Pairs [1,15] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, z), app(app(g, x), y))
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(d, z)
APP(app(g, app(e, x)), app(e, y)) → APP(app(g, x), y)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(filter2, app(f, x)), f)
APP(app(filter, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(h, z), app(e, x)) → APP(app(d, z), x)
APP(app(d, z), app(app(g, x), y)) → APP(e, x)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(app(app(filter2, app(f, x)), f), x), xs)
APP(app(map, f), app(app(cons, x), xs)) → APP(app(map, f), xs)
APP(app(h, z), app(e, x)) → APP(d, z)
APP(app(d, z), app(app(g, 0), 0)) → APP(e, 0)
APP(app(app(app(filter2, false), f), x), xs) → APP(app(filter, f), xs)
APP(app(app(app(filter2, true), f), x), xs) → APP(app(filter, f), xs)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(g, app(app(d, app(c, z)), app(app(g, x), y)))
APP(app(d, z), app(app(g, x), y)) → APP(app(g, app(e, x)), app(app(d, z), y))
APP(app(h, z), app(e, x)) → APP(c, z)
APP(app(h, z), app(e, x)) → APP(h, app(c, z))
APP(app(app(app(filter2, false), f), x), xs) → APP(filter, f)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(app(filter2, app(f, x)), f), x)
APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))
APP(app(map, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
APP(app(h, z), app(e, x)) → APP(app(h, app(c, z)), app(app(d, z), x))
APP(app(app(app(filter2, true), f), x), xs) → APP(cons, x)
APP(app(g, app(e, x)), app(e, y)) → APP(e, app(app(g, x), y))
APP(app(g, app(e, x)), app(e, y)) → APP(g, x)
APP(app(filter, f), app(app(cons, x), xs)) → APP(filter2, app(f, x))
APP(app(d, z), app(app(g, x), y)) → APP(g, app(e, x))
APP(app(map, f), app(app(cons, x), xs)) → APP(cons, app(f, x))
APP(app(app(app(filter2, true), f), x), xs) → APP(filter, f)
APP(app(app(app(filter2, true), f), x), xs) → APP(app(cons, x), app(app(filter, f), xs))
APP(app(map, f), app(app(cons, x), xs)) → APP(app(cons, app(f, x)), app(app(map, f), xs))

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

↳ QTRS
  ↳ DependencyPairsProof
QDP
      ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, z), app(app(g, x), y))
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(d, z)
APP(app(g, app(e, x)), app(e, y)) → APP(app(g, x), y)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(filter2, app(f, x)), f)
APP(app(filter, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(h, z), app(e, x)) → APP(app(d, z), x)
APP(app(d, z), app(app(g, x), y)) → APP(e, x)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(app(app(filter2, app(f, x)), f), x), xs)
APP(app(map, f), app(app(cons, x), xs)) → APP(app(map, f), xs)
APP(app(h, z), app(e, x)) → APP(d, z)
APP(app(d, z), app(app(g, 0), 0)) → APP(e, 0)
APP(app(app(app(filter2, false), f), x), xs) → APP(app(filter, f), xs)
APP(app(app(app(filter2, true), f), x), xs) → APP(app(filter, f), xs)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(g, app(app(d, app(c, z)), app(app(g, x), y)))
APP(app(d, z), app(app(g, x), y)) → APP(app(g, app(e, x)), app(app(d, z), y))
APP(app(h, z), app(e, x)) → APP(c, z)
APP(app(h, z), app(e, x)) → APP(h, app(c, z))
APP(app(app(app(filter2, false), f), x), xs) → APP(filter, f)
APP(app(filter, f), app(app(cons, x), xs)) → APP(app(app(filter2, app(f, x)), f), x)
APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))
APP(app(map, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
APP(app(h, z), app(e, x)) → APP(app(h, app(c, z)), app(app(d, z), x))
APP(app(app(app(filter2, true), f), x), xs) → APP(cons, x)
APP(app(g, app(e, x)), app(e, y)) → APP(e, app(app(g, x), y))
APP(app(g, app(e, x)), app(e, y)) → APP(g, x)
APP(app(filter, f), app(app(cons, x), xs)) → APP(filter2, app(f, x))
APP(app(d, z), app(app(g, x), y)) → APP(g, app(e, x))
APP(app(map, f), app(app(cons, x), xs)) → APP(cons, app(f, x))
APP(app(app(app(filter2, true), f), x), xs) → APP(filter, f)
APP(app(app(app(filter2, true), f), x), xs) → APP(app(cons, x), app(app(filter, f), xs))
APP(app(map, f), app(app(cons, x), xs)) → APP(app(cons, app(f, x)), app(app(map, f), xs))

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [15,17,22] contains 4 SCCs with 23 less nodes.

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
QDP
            ↳ QDPOrderProof
          ↳ QDP
          ↳ QDP
          ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(g, app(e, x)), app(e, y)) → APP(app(g, x), y)

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


APP(app(g, app(e, x)), app(e, y)) → APP(app(g, x), y)
The remaining pairs can at least be oriented weakly.
none
Used ordering: Polynomial interpretation [25,35]:

POL(APP(x1, x2)) = (4)x_1   
POL(g) = 0   
POL(e) = 1/4   
POL(app(x1, x2)) = (1/4)x_1 + (4)x_2   
The value of delta used in the strict ordering is 1.
The following usable rules [17] were oriented: none



↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
            ↳ QDPOrderProof
QDP
                ↳ PisEmptyProof
          ↳ QDP
          ↳ QDP
          ↳ QDP

Q DP problem:
P is empty.
The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The TRS P is empty. Hence, there is no (P,Q,R) chain.

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
QDP
            ↳ QDPOrderProof
          ↳ QDP
          ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, z), app(app(g, x), y))
APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, z), app(app(g, x), y))
The remaining pairs can at least be oriented weakly.

APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))
Used ordering: Polynomial interpretation [25,35]:

POL(APP(x1, x2)) = x_1   
POL(c) = 4   
POL(g) = 0   
POL(e) = 0   
POL(app(x1, x2)) = x_1 + x_2   
POL(d) = 0   
POL(0) = 0   
The value of delta used in the strict ordering is 4.
The following usable rules [17] were oriented: none



↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
          ↳ QDP
            ↳ QDPOrderProof
QDP
                ↳ QDPOrderProof
          ↳ QDP
          ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


APP(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → APP(app(d, app(c, z)), app(app(g, x), y))
The remaining pairs can at least be oriented weakly.

APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
Used ordering: Polynomial interpretation [25,35]:

POL(APP(x1, x2)) = x_2   
POL(c) = 0   
POL(g) = 0   
POL(e) = 0   
POL(app(x1, x2)) = (1/4)x_1 + (4)x_2   
POL(d) = 0   
POL(0) = 1/4   
The value of delta used in the strict ordering is 1.
The following usable rules [17] were oriented:

app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))



↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
          ↳ QDP
            ↳ QDPOrderProof
              ↳ QDP
                ↳ QDPOrderProof
QDP
                    ↳ QDPOrderProof
          ↳ QDP
          ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We use the reduction pair processor [15].


The following pairs can be oriented strictly and are deleted.


APP(app(d, z), app(app(g, x), y)) → APP(app(d, z), y)
The remaining pairs can at least be oriented weakly.
none
Used ordering: Polynomial interpretation [25,35]:

POL(APP(x1, x2)) = (1/2)x_2   
POL(g) = 4   
POL(app(x1, x2)) = (1/4)x_1 + x_2   
POL(d) = 0   
The value of delta used in the strict ordering is 1/8.
The following usable rules [17] were oriented: none



↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
          ↳ QDP
            ↳ QDPOrderProof
              ↳ QDP
                ↳ QDPOrderProof
                  ↳ QDP
                    ↳ QDPOrderProof
QDP
                        ↳ PisEmptyProof
          ↳ QDP
          ↳ QDP

Q DP problem:
P is empty.
The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The TRS P is empty. Hence, there is no (P,Q,R) chain.

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
          ↳ QDP
QDP
          ↳ QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(h, z), app(e, x)) → APP(app(h, app(c, z)), app(app(d, z), x))

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ DependencyGraphProof
        ↳ AND
          ↳ QDP
          ↳ QDP
          ↳ QDP
QDP

Q DP problem:
The TRS P consists of the following rules:

APP(app(filter, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(app(app(filter2, false), f), x), xs) → APP(app(filter, f), xs)
APP(app(app(app(filter2, true), f), x), xs) → APP(app(filter, f), xs)
APP(app(map, f), app(app(cons, x), xs)) → APP(f, x)
APP(app(map, f), app(app(cons, x), xs)) → APP(app(map, f), xs)

The TRS R consists of the following rules:

app(app(h, z), app(e, x)) → app(app(h, app(c, z)), app(app(d, z), x))
app(app(d, z), app(app(g, 0), 0)) → app(e, 0)
app(app(d, z), app(app(g, x), y)) → app(app(g, app(e, x)), app(app(d, z), y))
app(app(d, app(c, z)), app(app(g, app(app(g, x), y)), 0)) → app(app(g, app(app(d, app(c, z)), app(app(g, x), y))), app(app(d, z), app(app(g, x), y)))
app(app(g, app(e, x)), app(e, y)) → app(e, app(app(g, x), y))
app(app(map, f), nil) → nil
app(app(map, f), app(app(cons, x), xs)) → app(app(cons, app(f, x)), app(app(map, f), xs))
app(app(filter, f), nil) → nil
app(app(filter, f), app(app(cons, x), xs)) → app(app(app(app(filter2, app(f, x)), f), x), xs)
app(app(app(app(filter2, true), f), x), xs) → app(app(cons, x), app(app(filter, f), xs))
app(app(app(app(filter2, false), f), x), xs) → app(app(filter, f), xs)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.